<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
        <title>#{get 'title' /}</title>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
        <link rel="stylesheet" type="text/css" media="screen" href="/public/stylesheets/main.css"/>
        <link rel="stylesheet" type="text/css" media="screen" href="/public/stylesheets/requirement.css"/>
		<link rel="shortcut icon" href="@{'public/images/favicon.ico'}" type="image/x-icon"/> 
        #{get 'moreStyles' /}
 
        <script src="@{'/public/javascripts/jquery-1.4.min.js'}" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript" src="@{'public/javascripts/jquery-ui-1.8.custom.min.js'}"> </script>
		<script type="text/javascript" src="@{'public/javascripts/timepicker.js'}"> </script>
        <script src="@{'/public/javascripts/date.js'}" type="text/javascript" charset="utf-8"></script>
       	<script src="@{'/public/javascripts/md5.js'}" type="text/javascript"charset="utf-8"></script>
       	<script src="@{'/public/javascripts/more.js'}" type="text/javascript"charset="utf-8"></script>
		<script type="text/javascript" src="/public/javascripts/jquery.gritter.min.js"></script>
        <script src="@{'/public/javascripts/jquery.bar.js'}" type="text/javascript" charset="utf-8"></script>
        <script src="@{'/public/javascripts/requirements.js'}" type="text/javascript" charset="utf-8"></script>
        #{get 'moreScripts' /}
		
        <script type="text/javascript">
        var flag = false;
       		$(function(){
           		$.ajax();
       			doOnLoad();
       		});
       		function start()
       		{
       			if(!flag)
       			{	window.parent.$('#theLoadedContent').height($('#theWidth').height()+50);
       			fixFloat();
       				setTimeout("start()",1)
       			}
       		}

	       		function show()
	       		{
		       		#{if board}
		       	
		       			window.parent.$('#theLoadedContent').width(window.parent.$('body').width()-100);
	       				$('#theWidth').css('width','100%');
	       				$('body').css('overflow-x','auto');
			       #{/if}
		       		#{else}
		       			if(($('#theWidth').width()+200)<=window.parent.$('body').width()){
		       				window.parent.$('#theLoadedContent').width($('#theWidth').width()+200);
		       				$('#theWidth').css('width','100%');
		       			}
		       			else{
		       				window.parent.$('#theLoadedContent').width(window.parent.$('body').width()-100);
		       				$('#theWidth').css('width','100%');
		       				$('body').css('overflow-x','auto');
		       			}
				     #{/else}
		       		window.parent.$('#theLoadedContent').show();
		       		window.parent.$('#theLoadedContent').height($('#theWidth').height()+50);
		       		fixFloat();
		       		window.parent.$('#overlayLoading').hide();
		       		start();
		       	}
				function fixFloat()
				{
					if(window.parent.$('#theLoadedContent').height()<window.parent.$('body').height())
       				{
       		      		window.parent.$('#overlayContent').css('display','table');
       		      		window.parent.$('#overlayContent').css('position','fixed');
           			}
       				else
       				{
       					window.parent.$('#overlayContent').css('display','block');
       		      		window.parent.$('#overlayContent').css('position','absolute');
           			}
				}
	       		</script>

<style type="text/css">
thead {
	background: none repeat scroll 0 0 #333333;
	color: #EEEEEE;
	cursor: move;
	font-size: 12px;
}

h6 a,h6 {
	font-family: verdana !important;
	font-style: normal !important;
}

body,html {
	background: transparent !important;
	padding: 10px;
	overflow:hidden;
}
</style>
</head>
<body onload="show(); #{get 'onLoad'/};">
<div id="theWidth"style="display:table;width:auto">
<div style="position:fixed;right:10px;text-align:right;z-index:2147483647;">
<img height="25"width="25"onclick="hide();" style="cursor:pointer"src="@{'public/images/close.gif'}"/>
</div><div style="margin-top:40px;">
			#{doLayout /}</div>
			</div>
			<script type="text/javascript">
			$(document).ready(function(){

				#{ifErrors}
			parent_message_bar('${errors}');
			#{/ifErrors}

			#{if flash.error}
			parent_message_bar('&{flash.error}');
			#{/if}
				
			#{if error}
			parent_message_bar('&{error}');
			#{/if}
			
			#{if flash.success}
			parent_message_bar('&{flash.success}');
			#{/if}
			});
		
			</script>
		
</body>

</html>